package com.ts.common.exception;


/**
 * @author wangzun
 * @version 2019/4/27 上午9:09
 * @desc
 */
public class ExceptionFactory {

    public static BaseException createBaseException(int code, String message) {
        return new BaseException(code,message);
    }

    public static BaseException createWarnBaseException(String message) {
        return createBaseException(BaseException.WARNING_CODE,message);
    }

    public static BaseException createErrorBaseException(String message) {
        return createBaseException(BaseException.ERROR_CODE,message);
    }

    public static IllegalArgumentException createIllegalException(String message) {
        return new IllegalArgumentException(message);
    }
}
